home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / dcom / modems-part1 / 9251 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  3.6 KB

  1. Path: news-server.ncren.net!concert!ais!bruce
  2. From: bruce@ais.com
  3. Newsgroups: comp.dcom.modems
  4. Subject: Datacomm compression vs V.42bis compression (was Re: How come Z-Modem)
  5. Message-ID: <1996Mar26.100502.8753@ais>
  6. Date: 26 Mar 96 10:05:02 EST
  7. References: <4inro0$9mj@alcor.usc.edu> <4j7mp0$l33@sam.inforamp.net>
  8. Organization: Applied Information Systems, Chapel Hill, NC
  9.  
  10. In article <4j7mp0$l33@sam.inforamp.net>, crs0794@inforamp.net (Geoffrey Welsh) writes:
  11. > Oh, and yes... _full_ ZMODEM implementations include data compression, but 
  12. > with data compression built in to any decent modem these days, that's not
  13. > very important.
  14.  
  15. Relating to the subject of data compression inside a file transfer
  16. protocol, I have a question that I wonder if anyone has ever done
  17. the tests needed to come up with a definitive answer.
  18.  
  19. Given a pair of modems that use a decent-sized V.42bis dictionary,
  20. using the common file transfer / data communications protocols (ZMODEM,
  21. Kermit, SLIP, PPP), can you achieve faster overall throughput by turning
  22. on compression in the protocol, or by turning it off and allowing the
  23. modem to do the compression by itself?  Or does it matter much?  Assume
  24. that DTE speed is much greater than connect speed so that you are not DTE
  25. speed limited.  For the protocols that allow bidirectional traffic (SLIP
  26. and PPP), you should probably also limit the traffic to primarily one-way,
  27. with the return traffic being the minimum necessary to maintain the
  28. traffic flow.  Also, the size of the V.42bis dictionary needed to be
  29. "decent" is likely to be another parameter in the equation, as is the
  30. type of data being send by the protocol (some data being more compressable
  31. than others).
  32.  
  33. The point of the question is that, unlike compression algorithms such as
  34. the LZ algorithm used by GIF and ZIP, most file transfer and data comm
  35. protocols do compression by fairly simple "repeated byte elimination",
  36. that is, if you have a series of repeated bytes the algorithm will send
  37. these as something like:
  38.  
  39.     <REPEAT-INDICATOR> <REPEATED-BYTE> <REPEAT-COUNT>
  40.  
  41. (typically 3 bytes), rather than as, for example, the single token that
  42. represents a string of bytes used by more sophisticated algorithms.  Even
  43. if your file is fairly compressable using repeated byte elimination, you
  44. could find that the compression algorithm tends to defeat the dictionary
  45. used by LZ and V.42bis if there are a number of different combinations of
  46. <REPEATED-BYTE> and <REPEAT-COUNT> such that they tend to fill up the
  47. dictionary and crowd out potentially more useful strings.  (Of course
  48. this is likely to require somewhat pathological data :->).  Obviously
  49. you can also run into problems if the data contains a lot of the byte
  50. values used for the <REPEAT-INDICATOR> byte, so that you need to insert
  51. some kind of escape to change the normal meaning of that value, but let's
  52. assume that you're not sending random or pre-compressed data -- ie, that
  53. the data is text or executable or "normal" data files rather than ZIP or
  54. GIF files.  In addition, the types of compression achieved by repeated-
  55. byte elimination are likely to be similar in their effect to what can be
  56. achieved by V.42bis, so that the usefulness of using both is not obvious.
  57.  
  58. My _guess_ (and that's all that it is at this point) is that, assuming
  59. that you are not DTE-limited in some way, most of the time you'll find
  60. that it makes little or no detectable difference whether the DTE stream
  61. is compressed or not if the compression uses one of these simple schemes
  62. (formats such as ZIP _could_ achieve higher compression if they use a
  63. large enough dictionary).  But has anyone actually run any tests on this?
  64.  
  65. Bruce C. Wright
  66.